<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
   "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head>
    <title>Reference</title>
    <link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head>
<body>

<div id="container">

<div id="product">
	<div id="product_logo"></div>
	<div id="product_name"><big><b></b></big></div>
	<div id="product_description"></div>
</div> <!-- id="product" -->


<div id="main">


<!-- Menu -->

<div id="navigation">
<br/>
<h1>Duplex</h1>

<ul>
  <li><a href="../index.html">Index</a></li>
</ul>

<h2>Contents</h2>
<ul>
<li><a href="#Functions">Functions</a></li>
<li><a href="#Tables">Tables</a></li>
<li><a href="#Fields">Fields</a></li>
</ul>


<h2>Modules</h2>
<ul class="$(kind=='Topics' and '' or 'nowrap'">
  <li><a href="../modules/Duplex.Application.html">Duplex.Application</a></li>
  <li><a href="../modules/Duplex.Applications.Effect.html">Duplex.Applications.Effect</a></li>
  <li><a href="../modules/Duplex.Applications.GridPie.html">Duplex.Applications.GridPie</a></li>
  <li><a href="../modules/Duplex.Applications.Hydra.html">Duplex.Applications.Hydra</a></li>
  <li><a href="../modules/Duplex.Applications.Instrument.html">Duplex.Applications.Instrument</a></li>
  <li><a href="../modules/Duplex.Applications.Keyboard.GridLayout.html">Duplex.Applications.Keyboard.GridLayout</a></li>
  <li><a href="../modules/Duplex.Applications.Keyboard.Layouts.HarmonicLayout.html">Duplex.Applications.Keyboard.Layouts.HarmonicLayout</a></li>
  <li><a href="../modules/Duplex.Applications.Keyboard.Layouts.IsomorphicLayout.html">Duplex.Applications.Keyboard.Layouts.IsomorphicLayout</a></li>
  <li><a href="../modules/Duplex.Applications.Keyboard.Layouts.PianoLayout.html">Duplex.Applications.Keyboard.Layouts.PianoLayout</a></li>
  <li><a href="../modules/Duplex.Applications.Keyboard.html">Duplex.Applications.Keyboard</a></li>
  <li><a href="../modules/Duplex.Applications.Matrix.html">Duplex.Applications.Matrix</a></li>
  <li><a href="../modules/Duplex.Applications.Metronome.html">Duplex.Applications.Metronome</a></li>
  <li><a href="../modules/Duplex.Applications.MidiActions.Bindings.html">Duplex.Applications.MidiActions.Bindings</a></li>
  <li><a href="../modules/Duplex.Applications.MidiActions.html">Duplex.Applications.MidiActions</a></li>
  <li><a href="../modules/Duplex.Applications.Mixer.html">Duplex.Applications.Mixer</a></li>
  <li><a href="../modules/Duplex.Applications.Mlrx.Mlrx_group.html">Duplex.Applications.Mlrx.Mlrx_group</a></li>
  <li><a href="../modules/Duplex.Applications.Mlrx.Mlrx_note.html">Duplex.Applications.Mlrx.Mlrx_note</a></li>
  <li><a href="../modules/Duplex.Applications.Mlrx.Mlrx_pos.html">Duplex.Applications.Mlrx.Mlrx_pos</a></li>
  <li><a href="../modules/Duplex.Applications.Mlrx.Mlrx_track.html">Duplex.Applications.Mlrx.Mlrx_track</a></li>
  <li><a href="../modules/Duplex.Applications.Mlrx.html">Duplex.Applications.Mlrx</a></li>
  <li><a href="../modules/Duplex.Applications.Navigator.html">Duplex.Applications.Navigator</a></li>
  <li><strong>Duplex.Applications.NotesOnWheels</strong></li>
  <li><a href="../modules/Duplex.Applications.PatternCursor.html">Duplex.Applications.PatternCursor</a></li>
  <li><a href="../modules/Duplex.Applications.PatternSequence.html">Duplex.Applications.PatternSequence</a></li>
  <li><a href="../modules/Duplex.Applications.Recorder.html">Duplex.Applications.Recorder</a></li>
  <li><a href="../modules/Duplex.Applications.Repeater.html">Duplex.Applications.Repeater</a></li>
  <li><a href="../modules/Duplex.Applications.Rotate.html">Duplex.Applications.Rotate</a></li>
  <li><a href="../modules/Duplex.Applications.StepSequencer.html">Duplex.Applications.StepSequencer</a></li>
  <li><a href="../modules/Duplex.Applications.SwitchConfiguration.html">Duplex.Applications.SwitchConfiguration</a></li>
  <li><a href="../modules/Duplex.Applications.TestPad.html">Duplex.Applications.TestPad</a></li>
  <li><a href="../modules/Duplex.Applications.TrackSelector.html">Duplex.Applications.TrackSelector</a></li>
  <li><a href="../modules/Duplex.Applications.Transport.html">Duplex.Applications.Transport</a></li>
  <li><a href="../modules/Duplex.Applications.UIButtonTest.html">Duplex.Applications.UIButtonTest</a></li>
  <li><a href="../modules/Duplex.Applications.XYPad.html">Duplex.Applications.XYPad</a></li>
  <li><a href="../modules/Duplex.Automation.html">Duplex.Automation</a></li>
  <li><a href="../modules/Duplex.Browser.html">Duplex.Browser</a></li>
  <li><a href="../modules/Duplex.BrowserProcess.html">Duplex.BrowserProcess</a></li>
  <li><a href="../modules/Duplex.Canvas.html">Duplex.Canvas</a></li>
  <li><a href="../modules/Duplex.CanvasPoint.html">Duplex.CanvasPoint</a></li>
  <li><a href="../modules/Duplex.ControlMap.html">Duplex.ControlMap</a></li>
  <li><a href="../modules/Duplex.Device.html">Duplex.Device</a></li>
  <li><a href="../modules/Duplex.Display.html">Duplex.Display</a></li>
  <li><a href="../modules/Duplex.Globals.html">Duplex.Globals</a></li>
  <li><a href="../modules/Duplex.Message.html">Duplex.Message</a></li>
  <li><a href="../modules/Duplex.MessageStream.html">Duplex.MessageStream</a></li>
  <li><a href="../modules/Duplex.MidiDevice.html">Duplex.MidiDevice</a></li>
  <li><a href="../modules/Duplex.OscClient.html">Duplex.OscClient</a></li>
  <li><a href="../modules/Duplex.OscDevice.html">Duplex.OscDevice</a></li>
  <li><a href="../modules/Duplex.OscVoiceMgr.html">Duplex.OscVoiceMgr</a></li>
  <li><a href="../modules/Duplex.Preferences.html">Duplex.Preferences</a></li>
  <li><a href="../modules/Duplex.ProcessSlicer.html">Duplex.ProcessSlicer</a></li>
  <li><a href="../modules/Duplex.RoamingDSP.html">Duplex.RoamingDSP</a></li>
  <li><a href="../modules/Duplex.Scheduler.html">Duplex.Scheduler</a></li>
  <li><a href="../modules/Duplex.StateController.html">Duplex.StateController</a></li>
  <li><a href="../modules/Duplex.UIButton.html">Duplex.UIButton</a></li>
  <li><a href="../modules/Duplex.UIButtonStrip.html">Duplex.UIButtonStrip</a></li>
  <li><a href="../modules/Duplex.UIComponent.html">Duplex.UIComponent</a></li>
  <li><a href="../modules/Duplex.UIKey.html">Duplex.UIKey</a></li>
  <li><a href="../modules/Duplex.UIKeyPressure.html">Duplex.UIKeyPressure</a></li>
  <li><a href="../modules/Duplex.UILabel.html">Duplex.UILabel</a></li>
  <li><a href="../modules/Duplex.UIPad.html">Duplex.UIPad</a></li>
  <li><a href="../modules/Duplex.UIPitchBend.html">Duplex.UIPitchBend</a></li>
  <li><a href="../modules/Duplex.UISlider.html">Duplex.UISlider</a></li>
  <li><a href="../modules/Duplex.UISpinner.html">Duplex.UISpinner</a></li>
  <li><a href="../modules/Duplex.WidgetHooks.html">Duplex.WidgetHooks</a></li>
  <li><a href="../modules/Duplex.WidgetKeyboard.html">Duplex.WidgetKeyboard</a></li>
  <li><a href="../modules/Duplex.html">Duplex</a></li>
  <li><a href="../modules/main.html">main</a></li>
</ul>

</div>

<div id="content">

<h1>Module <code>Duplex.Applications.NotesOnWheels</code></h1>
<p>Notes On Wheels (N.O.W) is an arpeggiating step sequencer.</p>
<p>
<p>
Inheritance: <a href="../modules/Duplex.Application.html#">Duplex.Application</a> > Duplex.Application.NotesOnWheels </p>

<h3>Features</h3>
<p>N.O.W. allows you to create a sequence and control all aspects of each step (such as the pitch, velocity etc.) in realtime. </p>

<p>As for input, N.O.W. is very flexible, as you can control it via an additional MIDI input. Also, the virtual control surface will, when focused, detect and respond to keypresses within a specific range. </p>

<p>The virtual keyboard supports both ordinary transpose (one octave up/down from the middle C), and multi-step sequences (press keys while holding the SHIFT modifier). Same goes for the external MIDI keyboard, which can be set up to act upon CC messages and pitch bend. </p>


<h3>Controller setup</h3>

<p>A dedicated control surface is located in the Renoise tools menu:
Duplex > Custombuilt > Notes On Wheels</p>
<pre><code>_________________________________________________
|  _  _  _  _  _  _  _  _  _  _  _  _   _  _    |
| |_||_||_||_||_||_||_||_||_||_||_||_| |_||_|   | &lt;- Position + Line offset
|  _  _  _  _  _  _  _  _  _  _  _  _   ______  |
| (_)(_)(_)(_)(_)(_)(_)(_)(_)(_)(_)(_) |__||__| | &lt;- Pitch controls
|  _  _  _  _  _  _  _  _  _  _  _  _   ______  |
| (_)(_)(_)(_)(_)(_)(_)(_)(_)(_)(_)(_) |__||__| | &lt;- Velocity controls
|  _  _  _  _  _  _  _  _  _  _  _  _   ______  |
| (_)(_)(_)(_)(_)(_)(_)(_)(_)(_)(_)(_) |__||__| | &lt;- Offset controls
|  _  _  _  _  _  _  _  _  _  _  _  _   ______  |
| (_)(_)(_)(_)(_)(_)(_)(_)(_)(_)(_)(_) |__||__| | &lt;- Gate controls
|  _  _  _  _  _  _  _  _  _  _  _  _   ______  |
| (_)(_)(_)(_)(_)(_)(_)(_)(_)(_)(_)(_) |__||__| | &lt;- Retrigger controls
|  _  _  _  _  _  _  _  _  _  _  _  _   _  _    |
| |_||_||_||_||_||_||_||_||_||_||_||_| (_)(_)   | &lt;- Steps + Spacing/Length
|                                               |
| |Write| |Learn| |Fill| |Global| |Modes...|    | &lt;- Various controls
| ______________________________________________|
</code></pre>

<p>Also, check out the compact version, which use fewer controls, but still manages to contain every feature of it's bigger brother. This is possible because the sliders in that version are switching between the currently active mode (pitch, velocity etc.), and therefore, require only a small set of physical controls. Perhaps it's a more realistic starting point for your wn controller mapping than the fully expanded version? It's located here:
Duplex > Custombuilt > Notes On Wheels (compact)</p>


<h3>Discuss</h3>

<p>Tool discussion is located on the <a href="http://forum.renoise.com/index.php?/topic/31136-notes-on-wheels-now/">Renoise forum</a></p>


<h3>Changelog</h3>

<p>  0.98  </p>
<pre><code>- First release
</code></pre>


</p>


<h2><a href="#Functions">Functions</a></h2>
<table class="function_list">
	<tr>
	<td class="name" nowrap><a href="#__init">__init (VarArg)</a></td>
	<td class="summary">Constructor method</td>
	</tr>
	<tr>
	<td class="name" nowrap><a href="#start_app">start_app ()</a></td>
	<td class="summary">inherited from Application</td>
	</tr>
	<tr>
	<td class="name" nowrap><a href="#select_midi_port">select_midi_port (port_idx)</a></td>
	<td class="summary">initialize MIDI input</td>
	</tr>
	<tr>
	<td class="name" nowrap><a href="#midi_callback">midi_callback (message)</a></td>
	<td class="summary">receive MIDI from device</td>
	</tr>
	<tr>
	<td class="name" nowrap><a href="#schedule_output">schedule_output (seq_step, mask_mode)</a></td>
	<td class="summary">schedule output, simple way to reduce number of pattern writes:
 remember the last step / mode - if either change, output immediately</td>
	</tr>
	<tr>
	<td class="name" nowrap><a href="#output_sequence">output_sequence (seq_step, mask_mode, stream, force)</a></td>
	<td class="summary">output sequence to pattern</td>
	</tr>
	<tr>
	<td class="name" nowrap><a href="#on_idle">on_idle ()</a></td>
	<td class="summary">inherited from Application</td>
	</tr>
	<tr>
	<td class="name" nowrap><a href="#on_new_document">on_new_document ()</a></td>
	<td class="summary">inherited from Application</td>
	</tr>
	<tr>
	<td class="name" nowrap><a href="#disable_write_mode">disable_write_mode ()</a></td>
	<td class="summary">Update display of write mode</td>
	</tr>
	<tr>
	<td class="name" nowrap><a href="#on_keypress">on_keypress (key)</a></td>
	<td class="summary">inherited from Application</td>
	</tr>
	<tr>
	<td class="name" nowrap><a href="#create_empty_sequence">create_empty_sequence ()</a></td>
	<td class="summary">create or empty sequence</td>
	</tr>
	<tr>
	<td class="name" nowrap><a href="#_attach_to_instrument">_attach_to_instrument (new_song)</a></td>
	<td class="summary">attach to selected instrument</td>
	</tr>
	<tr>
	<td class="name" nowrap><a href="#detect_slices">detect_slices ()</a></td>
	<td class="summary">detect number of slices, and if using "white keys"</td>
	</tr>
	<tr>
	<td class="name" nowrap><a href="#to_sliced_pitch_range">to_sliced_pitch_range (int_val, invert)</a></td>
	<td class="summary">convert the pitch range (normally 0-121) to the sliced sample range
 (for example, middle C and every white key for the next two octaves)</td>
	</tr>
	<tr>
	<td class="name" nowrap><a href="#change_mode">change_mode (mode)</a></td>
	<td class="summary">when mode has changed</td>
	</tr>
	<tr>
	<td class="name" nowrap><a href="#shift">shift (amount)</a></td>
	<td class="summary">shift sequence in either direction
 if we have a pending offset, update that one as well</td>
	</tr>
	<tr>
	<td class="name" nowrap><a href="#_build_app">_build_app ()</a></td>
	<td class="summary">inherited from Application</td>
	</tr>
	<tr>
	<td class="name" nowrap><a href="#reset_adjustments">reset_adjustments ()</a></td>
	<td class="summary">reset adjustments
 will apply the default adjustment for each parameter,
 and update the display (dedicated/multi-control)</td>
	</tr>
</table>
<h2><a href="#Tables">Tables</a></h2>
<table class="function_list">
	<tr>
	<td class="name" nowrap><a href="#default_options">default_options</a></td>
	<td class="summary">These are the default options for the application</td>
	</tr>
	<tr>
	<td class="name" nowrap><a href="#available_mappings">available_mappings</a></td>
	<td class="summary">These are the available mappings for the application</p>

<p> Note: the <code>set<em>mode</em>[...]</code> mappings allow you to assign a mode directly to a specific button.</td>
	</tr>
	<tr>
	<td class="name" nowrap><a href="#white_keys">white_keys</a></td>
	<td class="summary">list of white keys</td>
	</tr>
	<tr>
	<td class="name" nowrap><a href="#self._controls">self._controls</a></td>
	<td class="summary">all UIComponent references are kept here
 create tables in advance, the rest ad hoc</td>
	</tr>
</table>
<h2><a href="#Fields">Fields</a></h2>
<table class="function_list">
	<tr>
	<td class="name" nowrap><a href="#self.step_focus">self.step_focus</a></td>
	<td class="summary">the step which was last modified (used for non-global output)</td>
	</tr>
	<tr>
	<td class="name" nowrap><a href="#self.number_of_slices">self.number_of_slices</a></td>
	<td class="summary">set to something else than 0 when instrument is sliced
 (tracked in realtime via the sample_mappings property)</td>
	</tr>
	<tr>
	<td class="name" nowrap><a href="#self.lower_note">self.lower_note</a></td>
	<td class="summary">remember where the sample mappings start/end
 (tracked in realtime via the sample_mappings property)</td>
	</tr>
	<tr>
	<td class="name" nowrap><a href="#self.white_keys_only">self.white_keys_only</a></td>
	<td class="summary">detect if sample mappings are 'white keys only'
 (tracked in realtime via the sample_mappings property)</td>
	</tr>
	<tr>
	<td class="name" nowrap><a href="#self.accept_note_input">self.accept_note_input</a></td>
	<td class="summary">true while the sequencer accepts incoming notes
 PC keyboard: when shift modifier is pressed</td>
	</tr>
	<tr>
	<td class="name" nowrap><a href="#self.has_received_input">self.has_received_input</a></td>
	<td class="summary">true, once we input using shift modifier</td>
	</tr>
	<tr>
	<td class="name" nowrap><a href="#self.midi_pressed_keys">self.midi_pressed_keys</a></td>
	<td class="summary">MIDI keys: remember pressed keys</td>
	</tr>
	<tr>
	<td class="name" nowrap><a href="#self.midi_max_keys">self.midi_max_keys</a></td>
	<td class="summary">MIDI keys: max number of simultaneously pressed keys</td>
	</tr>
	<tr>
	<td class="name" nowrap><a href="#self.scheduled_step">self.scheduled_step</a></td>
	<td class="summary">use these for scheduled output
 (assign a special value to make them output first time)</td>
	</tr>
	<tr>
	<td class="name" nowrap><a href="#self._blink">self._blink</a></td>
	<td class="summary">track playback progress in 'blinks'</td>
	</tr>
	<tr>
	<td class="name" nowrap><a href="#self.write_button_state">self.write_button_state</a></td>
	<td class="summary">the lit state of buttons</td>
	</tr>
	<tr>
	<td class="name" nowrap><a href="#self.track_changed">self.track_changed</a></td>
	<td class="summary">track changed?</td>
	</tr>
	<tr>
	<td class="name" nowrap><a href="#self.touched">self.touched</a></td>
	<td class="summary">when using the 'latch' write method, this will indicate
 that no control has yet been touched</td>
	</tr>
	<tr>
	<td class="name" nowrap><a href="#self._playing">self._playing</a></td>
	<td class="summary">the song is playing?</td>
	</tr>
	<tr>
	<td class="name" nowrap><a href="#self.realtime_pos">self.realtime_pos</a></td>
	<td class="summary">realtime position</td>
	</tr>
	<tr>
	<td class="name" nowrap><a href="#self.autolearn">self.autolearn</a></td>
	<td class="summary">when auto-learning is enabled</td>
	</tr>
	<tr>
	<td class="name" nowrap><a href="#self.just_entered_autolearn">self.just_entered_autolearn</a></td>
	<td class="summary">(bool) temporary flag set when entering autolearn mode</td>
	</tr>
	<tr>
	<td class="name" nowrap><a href="#self.seq">self.seq</a></td>
	<td class="summary">(NOW_Sequence) internal sequence representation</td>
	</tr>
	<tr>
	<td class="name" nowrap><a href="#self.last_line">self.last_line</a></td>
	<td class="summary">the pattern-line last detected by idle loop</td>
	</tr>
	<tr>
	<td class="name" nowrap><a href="#self.line_offset">self.line_offset</a></td>
	<td class="summary">the current line offset</td>
	</tr>
	<tr>
	<td class="name" nowrap><a href="#self.pending_line_offset">self.pending_line_offset</a></td>
	<td class="summary">the upcoming pattern's line offset</td>
	</tr>
	<tr>
	<td class="name" nowrap><a href="#self.pending_seq_pos">self.pending_seq_pos</a></td>
	<td class="summary">sequence-pos of upcoming pattern</td>
	</tr>
	<tr>
	<td class="name" nowrap><a href="#self.mode">self.mode</a></td>
	<td class="summary">(enum) the current mode</td>
	</tr>
	<tr>
	<td class="name" nowrap><a href="#self.write_method">self.write_method</a></td>
	<td class="summary">(enum) write method</td>
	</tr>
	<tr>
	<td class="name" nowrap><a href="#self.global_mode">self.global_mode</a></td>
	<td class="summary">(bool) global mode</td>
	</tr>
	<tr>
	<td class="name" nowrap><a href="#self.fill_mode">self.fill_mode</a></td>
	<td class="summary">(bool) fill mode</td>
	</tr>
	<tr>
	<td class="name" nowrap><a href="#self.write_mode">self.write_mode</a></td>
	<td class="summary">(bool) write mode</td>
	</tr>
	<tr>
	<td class="name" nowrap><a href="#self.midi_in">self.midi_in</a></td>
	<td class="summary">(renoise.Midi.MidiDevice)</td>
	</tr>
</table>

<br/>
<br/>


    <h2><a name="Functions"></a>Functions</h2>
    <dl class="function">
    <dt>
    <a name = "__init"></a>
    <strong>__init (VarArg)</strong>
    </dt>
    <dd>
    Constructor method


    <h3>Parameters:</h3>
    <ul>
        <li><span class="parameter">VarArg</span>
        )
        </li>
    </ul>



    <h3>See also:</h3>
    <ul>
         <a href="../modules/Duplex.Application.html#">Duplex.Application</a>
    </ul>


</dd>
    <dt>
    <a name = "start_app"></a>
    <strong>start_app ()</strong>
    </dt>
    <dd>
    inherited from Application



    <h3>Returns:</h3>
    <ol>

        bool or nil
    </ol>


    <h3>See also:</h3>
    <ul>
         <a href="../modules/Duplex.Application.html#start_app">Duplex.Application.start_app</a>
    </ul>


</dd>
    <dt>
    <a name = "select_midi_port"></a>
    <strong>select_midi_port (port_idx)</strong>
    </dt>
    <dd>
    initialize MIDI input


    <h3>Parameters:</h3>
    <ul>
        <li><span class="parameter">port_idx</span>



        </li>
    </ul>





</dd>
    <dt>
    <a name = "midi_callback"></a>
    <strong>midi_callback (message)</strong>
    </dt>
    <dd>
    receive MIDI from device


    <h3>Parameters:</h3>
    <ul>
        <li><span class="parameter">message</span>



        </li>
    </ul>





</dd>
    <dt>
    <a name = "schedule_output"></a>
    <strong>schedule_output (seq_step, mask_mode)</strong>
    </dt>
    <dd>
    schedule output, simple way to reduce number of pattern writes:
 remember the last step / mode - if either change, output immediately


    <h3>Parameters:</h3>
    <ul>
        <li><span class="parameter">seq_step</span>
         (int), step to output (can be nil)
        </li>
        <li><span class="parameter">mask_mode</span>
         (enum), restrict to specific mode (can be nil)
        </li>
    </ul>





</dd>
    <dt>
    <a name = "output_sequence"></a>
    <strong>output_sequence (seq_step, mask_mode, stream, force)</strong>
    </dt>
    <dd>
    output sequence to pattern


    <h3>Parameters:</h3>
    <ul>
        <li><span class="parameter">seq_step</span>
         (int), step to output (can be nil)
        </li>
        <li><span class="parameter">mask_mode</span>
         (enum), restrict to specific mode (can be nil)
        </li>
        <li><span class="parameter">stream</span>
         (bool), produce output in 'short bursts'
        </li>
        <li><span class="parameter">force</span>
         (bool), force output (e.g. when mode buttons are held)
        </li>
    </ul>





</dd>
    <dt>
    <a name = "on_idle"></a>
    <strong>on_idle ()</strong>
    </dt>
    <dd>
    inherited from Application





    <h3>See also:</h3>
    <ul>
         <a href="../modules/Duplex.Application.html#on_idle">Duplex.Application.on_idle</a>
    </ul>


</dd>
    <dt>
    <a name = "on_new_document"></a>
    <strong>on_new_document ()</strong>
    </dt>
    <dd>
    inherited from Application





    <h3>See also:</h3>
    <ul>
         <a href="../modules/Duplex.Application.html#on_new_document">Duplex.Application.on_new_document</a>
    </ul>


</dd>
    <dt>
    <a name = "disable_write_mode"></a>
    <strong>disable_write_mode ()</strong>
    </dt>
    <dd>
    Update display of write mode







</dd>
    <dt>
    <a name = "on_keypress"></a>
    <strong>on_keypress (key)</strong>
    </dt>
    <dd>
    inherited from Application


    <h3>Parameters:</h3>
    <ul>
        <li><span class="parameter">key</span>
         (table)
        </li>
    </ul>



    <h3>See also:</h3>
    <ul>
         <a href="../modules/Duplex.Application.html#on_keypress">Duplex.Application.on_keypress</a>
    </ul>


</dd>
    <dt>
    <a name = "create_empty_sequence"></a>
    <strong>create_empty_sequence ()</strong>
    </dt>
    <dd>
    create or empty sequence







</dd>
    <dt>
    <a name = "_attach_to_instrument"></a>
    <strong>_attach_to_instrument (new_song)</strong>
    </dt>
    <dd>
    attach to selected instrument


    <h3>Parameters:</h3>
    <ul>
        <li><span class="parameter">new_song</span>



        </li>
    </ul>





</dd>
    <dt>
    <a name = "detect_slices"></a>
    <strong>detect_slices ()</strong>
    </dt>
    <dd>
    detect number of slices, and if using "white keys"







</dd>
    <dt>
    <a name = "to_sliced_pitch_range"></a>
    <strong>to_sliced_pitch_range (int_val, invert)</strong>
    </dt>
    <dd>
    convert the pitch range (normally 0-121) to the sliced sample range
 (for example, middle C and every white key for the next two octaves)


    <h3>Parameters:</h3>
    <ul>
        <li><span class="parameter">int_val</span>
         (number) the value to scale
        </li>
        <li><span class="parameter">invert</span>
         (bool) when the value is sent to a control
        </li>
    </ul>





</dd>
    <dt>
    <a name = "change_mode"></a>
    <strong>change_mode (mode)</strong>
    </dt>
    <dd>
    when mode has changed


    <h3>Parameters:</h3>
    <ul>
        <li><span class="parameter">mode</span>
         (int, MODE<em>PITCH,MODE</em>VELOCITY,etc)
        </li>
    </ul>





</dd>
    <dt>
    <a name = "shift"></a>
    <strong>shift (amount)</strong>
    </dt>
    <dd>
    shift sequence in either direction
 if we have a pending offset, update that one as well


    <h3>Parameters:</h3>
    <ul>
        <li><span class="parameter">amount</span>
         (int)
        </li>
    </ul>





</dd>
    <dt>
    <a name = "_build_app"></a>
    <strong>_build_app ()</strong>
    </dt>
    <dd>
    inherited from Application



    <h3>Returns:</h3>
    <ol>

        bool
    </ol>


    <h3>See also:</h3>
    <ul>
         <a href="../modules/Duplex.Application.html#_build_app">Duplex.Application._build_app</a>
    </ul>


</dd>
    <dt>
    <a name = "reset_adjustments"></a>
    <strong>reset_adjustments ()</strong>
    </dt>
    <dd>
    reset adjustments
 will apply the default adjustment for each parameter,
 and update the display (dedicated/multi-control)







</dd>
</dl>
    <h2><a name="Tables"></a>Tables</h2>
    <dl class="function">
    <dt>
    <a name = "default_options"></a>
    <strong>default_options</strong>
    </dt>
    <dd>
    These are the default options for the application


    <h3>Fields:</h3>
    <ul>
        <li><span class="parameter">write_method</span>

<p> Select the desired write method </p>
<pre><code>WRITE_METHOD_TOUCH will only output notes while the controller is being used
WRITE_METHOD_LATCH will start output once the controller is being used
WRITE_METHOD_WRITE will output notes continously, no matter what
</code></pre>

        </li>
        <li><span class="parameter">edit_sync</span>
         Enable output when recording/edit-mode in Renoise is active
        </li>
        <li><span class="parameter">global_mode</span>
         Enable this to start the application in global mode
        </li>
        <li><span class="parameter">fill_mode</span>
         Enable this to start the application in fill mode
        </li>
        <li><span class="parameter">offset_quantize</span>
         Adjust this to divide a sample into a number of equally sized segments when (applied when using the sample-offset controls).
        </li>
        <li><span class="parameter">offset_wrap</span>
         Enable this to wrap the sample-offset
        </li>
        <li><span class="parameter">midi_keyboard</span>
         Select among available MIDI devices
        </li>
    </ul>





</dd>
    <dt>
    <a name = "available_mappings"></a>
    <strong>available_mappings</strong>
    </dt>
    <dd>
    These are the available mappings for the application</p>

<p> Note: the <code>set<em>mode</em>[...]</code> mappings allow you to assign a mode directly to a specific button.  If two or more modes are assigned in this way, they will act as radio buttons.
 As a secondary feature, hold any of these buttons for a moment, and the sequence will be written to the pattern, <code>fill mode</code>


    <h3>Fields:</h3>
    <ul>
        <li><span class="parameter">choose_mode</span>

<p> (UISlider) The mode determine which kind of output the 'Steps' dials will generate</p>
<pre><code>1 = Pitch - set the pitch of each step - max/min value will clear
2 = Velocity - set the volume of each step
3 = Offset - set the sample offset of each step
4 = Gate - set the length of each step, max is infinite
5 = Retrig - set the retrig rate of each step
</code></pre>

        </li>
        <li><span class="parameter">set_mode_pitch</span>
         (UIButton) Set mode to Pitch*
        </li>
        <li><span class="parameter">set_mode_velocity</span>
         (UIButton) Set mode to Velocity*
        </li>
        <li><span class="parameter">set_mode_offset</span>
         (UIButton) Set mode to Offset*
        </li>
        <li><span class="parameter">set_mode_gate</span>
         (UIButton) Set mode to Gate*
        </li>
        <li><span class="parameter">set_mode_retrig</span>
         (UIButton) Set mode to Gate*
        </li>
        <li><span class="parameter">multi_sliders</span>
         (group of UISliders) Specifies mode-dependant input dials (can control any parameter by switching mode)
        </li>
        <li><span class="parameter">pitch_sliders</span>
         (group of UISliders) Direct pitch control of each step
        </li>
        <li><span class="parameter">velocity_sliders</span>
         (group of UISliders) Direct velocity control of each step
        </li>
        <li><span class="parameter">offset_sliders</span>
         (group of UISliders) Direct offset control of each step
        </li>
        <li><span class="parameter">gate_sliders</span>
         (group of UISliders) Direct gate control of each step
        </li>
        <li><span class="parameter">retrig_sliders</span>
         (group of UISliders) Direct retrig control of each step
        </li>
        <li><span class="parameter">num_steps</span>
         (UISlider, 1-12) Set the number of steps in the sequence (mode-dependant)
        </li>
        <li><span class="parameter">step_spacing</span>
         (UISlider, 1-16) This value will determine the space between each note in lines (a value of 0 will output all notes simultaneously)
        </li>
        <li><span class="parameter">pitch_adjust</span>
         (UISlider) global pitch adjust (affects all steps)
        </li>
        <li><span class="parameter">velocity_adjust</span>
         (UISlider) global velocity adjust (affects all steps)
        </li>
        <li><span class="parameter">offset_adjust</span>
         (UISlider) global offset adjust (affects all steps)
        </li>
        <li><span class="parameter">gate_adjust</span>
         (UISlider) global gate adjust (affects all steps)
        </li>
        <li><span class="parameter">retrig_adjust</span>
         (UISlider) global retrig adjust (affects all steps)
        </li>
        <li><span class="parameter">multi_adjust</span>
         (UISlider) global adjust (affects all steps in given mode)
        </li>
        <li><span class="parameter">write</span>
         (UIButton) Toggles between output and no output (if you don't have room for this, check out @edit_sync)
        </li>
        <li><span class="parameter">learn</span>
         (UIButton) Import pattern editor data beginning from the cursor position
        </li>
        <li><span class="parameter">fill</span>
         (UIButton) Fill the entire track with the sequence, each time something changes. Use with caution, as this might be heavy on the CPU (with long patterns and many note columns)
        </li>
        <li><span class="parameter">global</span>
         (UIButton) Enable 'global' to output all parameters (pitch, velocity, etc.) at the same time. When off, only the modified parameter type is output
        </li>
        <li><span class="parameter">shift_up</span>
         (UIButton) Control the line-number offset (increase offset by a single line)
        </li>
        <li><span class="parameter">shift_down</span>
         (UIButton) Control the line-number offset (decrease offset by a single line)
        </li>
        <li><span class="parameter">extend</span>
         (UIButton) The 'extend' button will multiply the sequence's length by two, by cloning all steps and doubling the global retrig rate.
        </li>
        <li><span class="parameter">shrink</span>
         (UIButton) Pressing 'shrink' will reduce the length of the sequence and global retrig rate by 50%
        </li>
        <li><span class="parameter">position</span>
         (UIButton) Set the position of the sequence, based on the position of the edit cursor
        </li>
    </ul>





</dd>
    <dt>
    <a name = "white_keys"></a>
    <strong>white_keys</strong>
    </dt>
    <dd>
    list of white keys


    <h3>Fields:</h3>
    <ul>
        <li><span class="parameter">...</span>
         lot of keys
        </li>
    </ul>





</dd>
    <dt>
    <a name = "self._controls"></a>
    <strong>self._controls</strong>
    </dt>
    <dd>
    all UIComponent references are kept here
 create tables in advance, the rest ad hoc


    <h3>Fields:</h3>
    <ul>
        <li><span class="parameter">multi_sliders</span>



        </li>
        <li><span class="parameter">pitch_sliders</span>



        </li>
        <li><span class="parameter">velocity_sliders</span>



        </li>
        <li><span class="parameter">offset_sliders</span>



        </li>
        <li><span class="parameter">gate_sliders</span>



        </li>
        <li><span class="parameter">retrig_sliders</span>



        </li>
        <li><span class="parameter">pos_buttons</span>



        </li>
    </ul>





</dd>
</dl>
    <h2><a name="Fields"></a>Fields</h2>
    <dl class="function">
    <dt>
    <a name = "self.step_focus"></a>
    <strong>self.step_focus</strong>
    </dt>
    <dd>
    the step which was last modified (used for non-global output)







</dd>
    <dt>
    <a name = "self.number_of_slices"></a>
    <strong>self.number_of_slices</strong>
    </dt>
    <dd>
    set to something else than 0 when instrument is sliced
 (tracked in realtime via the sample_mappings property)







</dd>
    <dt>
    <a name = "self.lower_note"></a>
    <strong>self.lower_note</strong>
    </dt>
    <dd>
    remember where the sample mappings start/end
 (tracked in realtime via the sample_mappings property)







</dd>
    <dt>
    <a name = "self.white_keys_only"></a>
    <strong>self.white_keys_only</strong>
    </dt>
    <dd>
    detect if sample mappings are 'white keys only'
 (tracked in realtime via the sample_mappings property)







</dd>
    <dt>
    <a name = "self.accept_note_input"></a>
    <strong>self.accept_note_input</strong>
    </dt>
    <dd>
    true while the sequencer accepts incoming notes
 PC keyboard: when shift modifier is pressed







</dd>
    <dt>
    <a name = "self.has_received_input"></a>
    <strong>self.has_received_input</strong>
    </dt>
    <dd>
    true, once we input using shift modifier







</dd>
    <dt>
    <a name = "self.midi_pressed_keys"></a>
    <strong>self.midi_pressed_keys</strong>
    </dt>
    <dd>
    MIDI keys: remember pressed keys







</dd>
    <dt>
    <a name = "self.midi_max_keys"></a>
    <strong>self.midi_max_keys</strong>
    </dt>
    <dd>
    MIDI keys: max number of simultaneously pressed keys







</dd>
    <dt>
    <a name = "self.scheduled_step"></a>
    <strong>self.scheduled_step</strong>
    </dt>
    <dd>
    use these for scheduled output
 (assign a special value to make them output first time)







</dd>
    <dt>
    <a name = "self._blink"></a>
    <strong>self._blink</strong>
    </dt>
    <dd>
    track playback progress in 'blinks'







</dd>
    <dt>
    <a name = "self.write_button_state"></a>
    <strong>self.write_button_state</strong>
    </dt>
    <dd>
    the lit state of buttons







</dd>
    <dt>
    <a name = "self.track_changed"></a>
    <strong>self.track_changed</strong>
    </dt>
    <dd>
    track changed?  check via idle loop







</dd>
    <dt>
    <a name = "self.touched"></a>
    <strong>self.touched</strong>
    </dt>
    <dd>
    when using the 'latch' write method, this will indicate
 that no control has yet been touched







</dd>
    <dt>
    <a name = "self._playing"></a>
    <strong>self._playing</strong>
    </dt>
    <dd>
    the song is playing?  check via idle loop







</dd>
    <dt>
    <a name = "self.realtime_pos"></a>
    <strong>self.realtime_pos</strong>
    </dt>
    <dd>
    realtime position







</dd>
    <dt>
    <a name = "self.autolearn"></a>
    <strong>self.autolearn</strong>
    </dt>
    <dd>
    when auto-learning is enabled







</dd>
    <dt>
    <a name = "self.just_entered_autolearn"></a>
    <strong>self.just_entered_autolearn</strong>
    </dt>
    <dd>
    (bool) temporary flag set when entering autolearn mode







</dd>
    <dt>
    <a name = "self.seq"></a>
    <strong>self.seq</strong>
    </dt>
    <dd>
    (NOW_Sequence) internal sequence representation







</dd>
    <dt>
    <a name = "self.last_line"></a>
    <strong>self.last_line</strong>
    </dt>
    <dd>
    the pattern-line last detected by idle loop







</dd>
    <dt>
    <a name = "self.line_offset"></a>
    <strong>self.line_offset</strong>
    </dt>
    <dd>
    the current line offset







</dd>
    <dt>
    <a name = "self.pending_line_offset"></a>
    <strong>self.pending_line_offset</strong>
    </dt>
    <dd>
    the upcoming pattern's line offset







</dd>
    <dt>
    <a name = "self.pending_seq_pos"></a>
    <strong>self.pending_seq_pos</strong>
    </dt>
    <dd>
    sequence-pos of upcoming pattern







</dd>
    <dt>
    <a name = "self.mode"></a>
    <strong>self.mode</strong>
    </dt>
    <dd>
    (enum) the current mode







</dd>
    <dt>
    <a name = "self.write_method"></a>
    <strong>self.write_method</strong>
    </dt>
    <dd>
    (enum) write method







</dd>
    <dt>
    <a name = "self.global_mode"></a>
    <strong>self.global_mode</strong>
    </dt>
    <dd>
    (bool) global mode







</dd>
    <dt>
    <a name = "self.fill_mode"></a>
    <strong>self.fill_mode</strong>
    </dt>
    <dd>
    (bool) fill mode







</dd>
    <dt>
    <a name = "self.write_mode"></a>
    <strong>self.write_mode</strong>
    </dt>
    <dd>
    (bool) write mode







</dd>
    <dt>
    <a name = "self.midi_in"></a>
    <strong>self.midi_in</strong>
    </dt>
    <dd>
    (renoise.Midi.MidiDevice)







</dd>
</dl>


</div> <!-- id="content" -->
</div> <!-- id="main" -->
<div id="about">
<i>generated by <a href="http://github.com/stevedonovan/LDoc">LDoc 1.4.2</a></i>
</div> <!-- id="about" -->
</div> <!-- id="container" -->
</body>
</html>
